package camel.corp.universalcopy;

import android.content.Intent;
import android.net.Uri;
import android.preference.Preference;
import com.camel.corp.universalcopy.MaterialSwitchPreference;
import com.camel.corp.universalcopy.da;
import com.camel.corp.universalcopy.ga;

class da implements Preference.OnPreferenceChangeListener {
  da(ga paramga, Boolean paramBoolean) {}
  
  public boolean onPreferenceChange(Preference paramPreference, Object paramObject) {
    boolean bool1 = ((Boolean)paramObject).booleanValue();
    boolean bool2 = ((MaterialSwitchPreference)paramPreference).isChecked();
    if (this.a.booleanValue() == bool1)
      return true; 
    if (bool2 != bool1) {
      String str;
      paramObject = new Intent();
      paramObject.setFlags(268435456);
      if (bool1) {
        str = "android.settings.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS";
      } else {
        str = "android.settings.IGNORE_BATTERY_OPTIMIZATION_SETTINGS";
      } 
      paramObject.setAction(str);
      if (bool1) {
        StringBuilder stringBuilder = new StringBuilder();
        stringBuilder.append("package:");
        stringBuilder.append(this.b.getActivity().getPackageName());
        paramObject.setData(Uri.parse(stringBuilder.toString()));
      } 
      this.b.startActivity(paramObject);
      return false;
    } 
    return true;
  }
}


/* Location:              D:\Users\alienware\AndroidStudioProjects\Lazero\sample\sampler\classes-dex2jar\com\camel.jar!\camel\cor\\universalcopy\da.class
 * Java compiler version: 6 (50.0)
 * JD-Core Version:       1.0.7
 */